package chapter_Thread_Sleep;

public class ClimbThread implements Runnable{
	
	private int time;


	public ClimbThread(int time) {
		this.time = time;
	}
	

    public void run() {
    	for(int i = 0;i<10;i++) {
				System.out.println(Thread.currentThread().getName()+"爬完了100米");
				try {
					Thread.sleep(this.time);
				}catch(InterruptedException e) {
					e.printStackTrace();
				}
				
		}
		System.out.println(Thread.currentThread().getName()+"到达终点！");
	}
    
  
}
